/**
 * NOTE HOST、HOST_M 是在 config 中通过 defineConstants 配置的
 * 只所以不在代码中直接引用，是因为 eslint 会报 no-undef 的错误，因此用如下方式处理
 */
/* eslint-disable */
export const host = HOST
export const hostM = HOST_M
/* eslint-enable */

// pic
export const CDN = 'https://yanxuan.nosdn.127.net'

// home
export const API_HOME = `${host}/index`

// cate
export const API_CATE = `${host}/item/category/list`
export const API_CATE_SUB = `${host}/item/category/sub`
export const API_CATE_SUB_LIST = `${host}/item/list/l2Items2`

// cart
export const API_CART_INFO = `${host}/cart/list`
export const API_CART_SAVE = `${host}/cart/save`
export const API_CART_UPDATE = `${host}/cart/update`
export const API_CART_DELETE = `${host}/cart/delete`
export const API_CART_SELECT_ALL = `${host}/cart/selectAll`

// user
export const API_USER = `${host}/user/info`
export const API_USER_LOGIN = `${host}/login/weapp/phone`
export const API_CHECK_LOGIN = `${host}/user/info`

// item
export const API_ITEM = `${host}/item/detail`
export const API_ITEM_SEARCH = `${host}/item/search`
export const API_ITEM_SEARCH_HOT = `${host}/item/search/hot`
export const API_ITEM_RECOMMEND = `${host}/item/recommend`

// address
export const API_ADDRESS = `${host}/address/list`
export const API_ADDRESS_SAVE = `${host}/address/save`
export const API_ADDRESS_DELETE = `${host}/address/del`
export const API_ADDRESS_INFO = `${host}/address/info`

// order
export const API_ORDER_LIST = `${host}/order/list`
export const API_ORDER_SETTLEMENT = `${host}/order/settlement`
export const API_ORDER_SUBMIT = `${host}/order/submit`
export const API_ORDER_INFO = `${host}/order/info`
export const API_ORDER_CANCEL = `${host}/order/cancel`
export const API_ORDER_PAY = `${host}/order/pay`
export const API_ORDER_CONFIRM = `${host}/order/confirm`
export const API_ORDER_DELETE = `${host}/order/delete`
export const API_ORDER_AS_CREATE = `${host}/order/after-sale/create`
export const API_ORDER_AS_LIST = `${host}/order/after-sale/list`
export const API_ORDER_LOGISTICS = `${host}/order/logistics/track`
// coupon
export const API_COUPON_LIST = `${host}/coupon/list`
export const API_COUPON_RECEIVE = `${host}/coupon/receive`
